package com.hlkj.pay.dto.provider;
/*
 * Hlpay-Plus aggregate payment system.
 * Copyright (c) 2024-2025 Hlpay Team Copyright has the right of final interpretation.
 */

import java.math.BigDecimal;

import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;

import com.hlkj.framework.common.valid.EnumValid;
import com.hlkj.pay.enums.PayEnums;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
 * @author HlpayTeam
 * @date 2024/09/23 16:18
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class DefaultFeeConfig {
	
	@Schema(description = "费率类型 1 百分比 2 固定值 3 百分比+固定值 ")
	@EnumValid(value = PayEnums.FEE_TYPE.class, message = "费率类型 无效")
	@NotNull(message = "费率类型 不能为空")
	private Integer feeType;
	@Schema(description = "百分比费率底价")
	@Max(value = 100,message = "百分比费率底价 必须必须小于100")
	@Min(value = 0,message = "百分比费率底价 必须必须大于0")
	private BigDecimal rateBase;
	@Schema(description = "固定费率底价")
	@Max(value = 100,message = "固定费率底价 必须必须小于100")
	@Min(value = 0,message = "固定费率底价 必须必须大于0")
	private BigDecimal fixedRate;
	
}
